package com.cx.mall.demo.service.impl;

import com.baomidou.mybatisplus.extension.conditions.query.LambdaQueryChainWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.cx.mall.demo.mapper.DemoUserInfoMapper;
import com.cx.mall.demo.model.UserInfo;
import com.cx.mall.demo.service.IDemoUserInfoService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("demoUserInfoServiceImpl")
public class DemoUserInfoServiceImpl extends ServiceImpl<DemoUserInfoMapper,UserInfo> implements IDemoUserInfoService {
    @Override
    public List<UserInfo> queryUserInfoById(long id) {
        LambdaQueryChainWrapper<UserInfo> wrapper = new LambdaQueryChainWrapper<>(baseMapper);
        List<UserInfo> list = wrapper.eq(UserInfo::getId, id).list();
        return list;
    }
}
